# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-nltk
_pkgname=nltk
pkgver=3.4.5
pkgrel=3
pkgdesc='Natural language processing in Python.'
arch=('any')
url='https://pypi.org/project/nltk/#files'
license=('APACHE')
depends=('python2-yaml')
makedepends=('python2-setuptools')
optdepends=('nltk-data: test data'
            'python2-numpy: used for calculations'
            'python2-matplotlib: used for plotting')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.zip")
sha512sums=('d4c312533324402fe1b86f22a0ea14af8e34fc8c3f34bca5d5e63df4dff6317d84f6f9828fad4e404defeaaddb3e4f7c22a05874064ca7526e0c280ed5afdd91')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

